package com.sync.syncmasterdata.customer.repository.oarep;

import com.sync.syncmasterdata.customer.entity.oa.OACustomerEntity;
import com.sync.syncmasterdata.customer.entity.oa.OACustomerWFEntity;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 客户档案 dao 持久类
 */
@Repository
public interface OACustomerWFRepository extends JpaRepository<OACustomerWFEntity,Integer> {
    /**
     * oa数据库查询 流程OA客户对象（重复用）
     * @param requestid
     * @return
     */
    @Query(nativeQuery = true, value= "select * from formtable_main_4 where requestid=:requestid")
    OACustomerWFEntity getOACustomerWFEntityByRequestid(@Param(value = "requestid") String requestid);

}
